package com.xlh.support.experimentshare.websocket.message;

import com.xlh.enums.WebsocketMessageEnum;
import com.xlh.websocket.message.Message;
import lombok.Builder;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * @author cheer
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class ShareCloseMessage extends Message {

    /**
     * 共享的章节Id
     */
    private Long chapterId;

    @Builder
    public ShareCloseMessage(Long userId, String username, Long chapterId) {
        super.setType(WebsocketMessageEnum.SHARE_CLOSE.getCode());
        super.setUserId(userId);
        super.setUsername(username);
        this.chapterId = chapterId;
    }
}
